<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>

<header class="main-header">
    <!-- Logo -->
    <a href="#" class="logo">
        <!-- mini logo for sidebar mini 50x50 pixels -->
        <span class="logo-mini"><b>505</b></span>
        <!-- logo for regular state and mobile devices -->
        <span class="logo-lg"><b>医院信息化管理系统</b></span>
    </a>
    <!-- Header Navbar: style can be found in header.less -->
    <nav class="navbar navbar-static-top">

        <a href="#" class="sidebar-toggle" data-toggle="push-menu" role="button">
            <span class="sr-only">Toggle navigation</span>
        </a>
        <div class="navbar-custom-menu">

            <ul class="nav navbar-nav">
                <!-- User Account: style can be found in dropdown.less -->
                <li class="dropdown user user-menu">
                    <a href="#" class="dropdown-toggle" data-toggle="dropdown"
                       style="padding:15px; padding-bottom:35px;padding-right: 5px;">
                        <img src=${usermax.username=="T002"?"static/assets/img/user3-128x128.jpg":"static/assets/img/user2-160x160.jpg"} class="user-image"
                             alt="User Image">
                        <span class="hidden-xs">${usermax.username}</span>
                    </a>
                    <ul class="dropdown-menu">
                        <!-- User image -->
                        <li class="user-header">
                            <img src="static/assets/img/user2-160x160.jpg"} class="img-circle"
                                 alt="User Image">
                            <p>
                                ${usermax.username}
                                <small><fmt:formatDate value=""
                                                       pattern="yyyy-MM-dd HH:mm:ss"/> </small>
                            </p>
                        </li>

                        <!-- Menu Footer-->
                        <li class="user-footer">
                            <div class="pull-left">
                                <a class="btn btn-default btn-flat"
                                   onclick="showInfo1('userdetail?jobnumber=${usermax.username}')">个人信息</a>
                            </div>
                            <div class="pull-right">
                                <a href="logout" class="btn btn-default btn-flat">退出系统</a>
                            </div>
                        </li>
                    </ul>
                </li>
            </ul>
        </div>
    </nav>

</header>
<script>
    function showInfo1(url) {
        $.ajax({
            url: url,
            type: "GET",
            dataType: "html",
            success: function (data) {
                $("#modal-detail-body").html(data);
                $("#modal-detail").modal("show")
            }
        })

    }
</script>